<?php
 require'pdo.php';
 $dsn="{$dbtype}:host={$host};dbname={$dbname}";
try{
	$pdo=new PDO($dsn,$username,$password);
	$updateTime=time();
	$sql="SELECT id FROM result";
	$result=$pdo->query($sql);
	if($result && $result->rowCount()){
		$result->setFetchMode(PDO::FETCH_ASSOC);
		$row=$result->fetch();
		print_r($row);
	}
}catch(PDOException $e){
	die('操作失败'.$e->getMessage());
}